<template>
	<view class="">

	</view>
</template>
<script>
	export default {
		globalData: {},
		onLaunch: function() {
			console.log('App Launch')
			uni.getSystemInfo({ //设置屏幕高度
				success: res => {
					//减去tabbar的高度，默认为50px
					this.globalData.screenHeight = res.screenHeight;
					this.globalData.windowHeight = res.windowHeight;
					console.log(res)
				}
			})
			this.initLogin();
		},
		onShow: function() {
			console.log('App Show')
		},
		onHide: function() {
			console.log('App Hide')
		},
		methods:{
			//登录状态
			async initLogin() {
				const token = uni.getStorageSync('token');
				const expire = uni.getStorageSync('expire');
				const mark = uni.getStorageSync('mark');
				this.log(token, expire, mark);
				if (token) {
					this.$store.commit('setToken', {
						mark,
						token,
						expire
					});
				}
			},
		}
	}
</script>
<style lang="scss">
	@import "./uni_modules/vk-uview-ui/index.scss";
	@import "./style/button.scss";
	@import "./style/color.scss";
	/*每个页面公共css */
</style>